# try...except...else结构
try:
    n1 = int(input('输入第一个数'))
    n2 = int(input('输入第二个数'))
    result = n1 / n2
except BaseException as e:
    print(e)
else:
    print(result)
finally:
    print('无论是否产生异常,总会被执行的代码')
